/*
 * @Author: Smthie Smthie@qq.com
 * @Date: 2024-05-16 11:01:45
 * @LastEditors: Smthie Smthie@qq.com
 * @LastEditTime: 2024-05-29 16:26:02
 * @FilePath: \ProtocolTool\src\renderer\src\api\Manual.ts
 */
import request from '@/utils/request'
// 获取在线设备列表
export const getOnlineDeviceAPI = () => request.get('/instr-info/onlineList')
// 获取模板数据
export const getTemplateAPI = (params: any) => request.get('/item-template/getTemplate', { params })

/**
 * MQTT指令传输部分
 **/
// 获取工作参数
export const instructGetParamsAPI = (data) => request.post('/instruct/param/query', data)
// 设置工作参数
export const instructSetParamsAPI = (data) => request.post('/instruct/param/set', data)
// 运行日志
export const instructLogAPI = (data) => request.post('/instruct/log', data)
// 告警信息
export const instructAlarmAPI = (data) => request.post('/instruct/alarm', data)
// 设备控制
export const instructDeviceCtrlAPI = (data) => request.post('/instruct/control', data)
// 切换账号
export const instructSwitchAccountAPI = (data) => request.post('/instruct/switchAccount', data)
// 获取属性信息
export const instructGetAttrbuiteAPI = (data) => request.post('/instruct/attribute', data)
// 测量数据
export const instructMetricalAPI = (data) => request.post('/instruct/metrical', data)
// 获取状态信息
export const instructStatusAPI = (data) => request.post('/instruct/status', data)

/**
 * Socket传输部分
 **/
// 实时测量数据
export const socketRealTimeDataAPI = (data) => request.post('/socket/realTimeData', data)
// 当前测量数据
export const socketCurrentDataAPI = (data) => request.post('/socket/currentData', data)
// 整体测量数据
export const socketCustomDataAPI = (data) => request.post('/socket/customData', data)
// 事件记录测量数据
export const socketEventDataAPI = (data) => request.post('/socket/eventData', data)
// 获取工作参数
export const socketGetParamAPI = (data) => request.post('/socket/getParam', data)
// 设置工作参数
export const socketSetParamAPI = (data) => request.post('/socket/setParam', data)
// 获取属性信息
export const socketGetAttributeAPI = (data) => request.post('/socket/getAttribute', data)
// 获取状态信息
export const socketGetStatusAPI = (data) => request.post('/socket/getStatus', data)
// 用户登录
export const socketUserLoginAPI = (data) => request.post('/socket/userLogin', data)
// 修改密码
export const socketUpdatePasswordAPI = (data) => request.post('/socket/updatePassword', data)
// 运行日志
export const socketRunLogAPI = (data) => request.post('/socket/runLog', data)
// 设备控制
export const socketDeviceCtrlAPI = (data) => request.post('/socket/deviceControl', data)
